package pt.isel.pdm.ouryamba;

public interface IMyListener 
{
	/**
	 * Specify a callback for anyone who implements this interface.
	 * 
	 * The parameter is useful because the service notifies everyone inside the {@code toNotifyList}
	 * and send that token to each one. The token will be used by the "waken" Components to verify
	 * if that token corresponds to the own private token.
	 * Basically the service notifies everyone and each one checks if it is the one that should be
	 * "awaken".  
	 * 
	 * Why do we need this?
	 * Because when we make an interaction from some Component to the Service and we want that
	 * Component to receive a feedback that the Service has completed the work,. Then some action
	 * will be taken on the Component side (probably on the UI thread).
	 * 
	 * @param token Represent a token that should match the private token of this component.
	 * */
	public void onSuccess(Integer token);
}
